#ifndef __UserLoginSection2_H__
#define __UserLoginSection2_H__

#include "TLV.hpp"
#include "Packet.hpp"
#include "TcpConnection.hpp"
namespace wd
{
class UserLoginSection2
{
public:
    UserLoginSection2(TcpConnectionPtr conn,Packet packet)
    :_packet(packet)
    ,_conn(conn)
    {}
    //解析客户端发送的是用户名：加密密码
    bool parseClientData(const string & data,string &username,string &clientEncrypt);
    //数据库查询用户的加密密文
    string getDbEncrypt(const string&username);
    void process();
private:
    Packet _packet;
    TcpConnectionPtr _conn;
};
}






#endif

